package com.wasion.gydpe.common.util;

import java.io.IOException;
import java.io.InputStream;
import java.util.Properties;

/**
 * 
 * @ClassName: ConfigUtil
 * @Description: 系统配置工具类
 * @author 高意
 * @date Oct 18, 2012 10:08:46 AM
 * 
 */
public class ConfigUtil {

	private static Properties config = null;

	static {
		InputStream in = ConfigUtil.class.getClassLoader()
				.getResourceAsStream("config/system.properties");
		config = new Properties();
		try {
			config.load(in);
			in.close();
		} catch (IOException e) {
			System.out.println("No system.properties defined error");
		}
	}

	public static String getValueByKey(String key) {
		return config.getProperty(key).trim();
	}
}
